<!DOCTYPE html>
<html lang="en" xmlns:th="http://www.thymeleaf.org">
<head>
    <meta charset="UTF-8">
    <title>用户列表</title>
    <link rel="stylesheet" type="text/css" th:href="@{/layui/css/layui.css}"/>
</head>
<body>
    <div class="layui-row">
        <div class="layui-col-md8 layui-col-md-offset2" style="border: 1px solid">
            <div style="padding: 16px;">
                <table class="layui-hide" id="table" lay-filter="tableFilter"></table>
            </div>
        </div>

    </div>

<script th:src="@{/layui/layui.js}"></script>
<script>
    let ctx = '[[${#request.contextPath}]]';
</script>
<script type="text/html" id="templet-user">
    <a href="{{= ctx + '/user/' + d.id }}" target="_blank">{{= d.username }}</a>
</script>
<script type="text/html" id="toolbar">
    <button onclick="update('{{=d.id}}')" class="layui-btn layui-btn-xs layui-btn-normal">修改</button>
    <button onclick="del('{{=d.id}}')" class="layui-btn layui-btn-xs layui-btn-danger">删除</button>
</script>

<script th:src="@{/service/user/user.js}"></script>
</body>
</html>